package com.my.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FilterType;
import org.springframework.stereotype.Controller;

@Configuration
@ComponentScan(basePackages = "com.my.*", excludeFilters = @ComponentScan.Filter(
        type = FilterType.ANNOTATION, classes = {Controller.class, Configuration.class}))
public class SpringConfig {

    @Bean(name = "str")
    public String str() {
        System.out.println("sss...");
        return new String("str");
    }
}
